package com.dd.admin.business.product.entity;

import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import java.util.Date;
import com.baomidou.mybatisplus.annotation.Version;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableField;
import java.io.Serializable;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * <p>
 * 商品
 * </p>
 *
 * @author 727869402@qq.com
 * @since 2024-05-23
 */
@Data
@EqualsAndHashCode(callSuper = false)
@TableName("business_product")
@ApiModel(value="Product对象", description="商品")
public class Product implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "商品id")
    @TableId(value = "PRODUCT_ID", type = IdType.ASSIGN_UUID)
    private String productId;

    @ApiModelProperty(value = "分类id")
    @TableField("CATEGORY_ID")
    private String categoryId;

    @ApiModelProperty(value = "分类名")
    @TableField("CATEGORY_NAME")
    private String categoryName;

    @ApiModelProperty(value = "商品名")
    @TableField("PRODUCT_NAME")
    private String productName;

    @ApiModelProperty(value = "商品金额")
    @TableField("PRODUCT_AMOUNT")
    private BigDecimal productAmount;

    @ApiModelProperty(value = "商品会员金额")
    @TableField("PRODUCT_MEMBER_AMOUNT")
    private BigDecimal productMemberAmount;

    @ApiModelProperty(value = "商品图片")
    @TableField("PRODUCT_IMAGE")
    private String productImage;

    @ApiModelProperty(value = "库存数量")
    @TableField("PRODUCT_COUNT")
    private Long productCount;

    @ApiModelProperty(value = "库存数量")
    @TableField(exist = false)
    private Long count;


    @ApiModelProperty(value = "提成金额")
    @TableField("PUSH_AMOUNT")
    private BigDecimal pushAmount;

    @ApiModelProperty(value = "提成比例")
    @TableField("PUSH_PERCENT")
    private BigDecimal pushPercent;

    @ApiModelProperty(value = "0正常 1下架")
    @TableField("PRODUCT_STATUS")
    private Integer productStatus;

    @ApiModelProperty(value = "乐观锁字段")
    @TableField("VERSION")
    @Version
    private Long version;

    @ApiModelProperty(value = "0正常 1删除")
    @TableField("DELETED")
    @TableLogic
    private Integer deleted;

    @ApiModelProperty(value = "门店id")
    @TableField(value = "SHOP_ID", fill = FieldFill.INSERT)
    private String shopId;

    @ApiModelProperty(value = "门店名")
    @TableField(value = "SHOP_NAME", fill = FieldFill.INSERT)
    private String shopName;

    @ApiModelProperty(value = "创建人")
    @TableField(value = "CREATE_NAME", fill = FieldFill.INSERT)
    private String createName;

    @ApiModelProperty(value = "创建时间")
    @TableField(value = "CREATE_TIME", fill = FieldFill.INSERT)
    private Date createTime;

    @ApiModelProperty(value = "创建人id")
    @TableField(value = "CREATE_ID", fill = FieldFill.INSERT)
    private String createId;

    @ApiModelProperty(value = "修改时间")
    @TableField(value = "UPDATE_TIME", fill = FieldFill.UPDATE)
    private Date updateTime;

    @ApiModelProperty(value = "修改人")
    @TableField(value = "UPDATE_NAME", fill = FieldFill.UPDATE)
    private String updateName;

    @ApiModelProperty(value = "修改人id")
    @TableField(value = "UPDATE_ID", fill = FieldFill.UPDATE)
    private String updateId;

    @ApiModelProperty(value = "0不开启 1开启")
    @TableField("STOCK_CONTROL")
    private Integer stockControl;

    @ApiModelProperty(value = "0固定金额 1比例")
    @TableField("PUSH_TYPE")
    private Integer pushType;
}
